<template>
  <div>
    <div>{{ message | capitalize }}</div>
    <input type="text" :value="message | capitalize" />
  </div>
</template>

<script>
export default {
  name: 'Filter',
  data () {
    return {
      message: 'abcdefghijklmnkol'
    }
  },
  filters: {
    capitalize: function (value) {
      if (!value) {
        return ''
      }
      value = value.toString()
      return value.charAt(0).toUpperCase() + value.slice(1)
    }
  }
}
</script>
<style lang="less" scoped></style>
